<admintpl file="header_adminlte" />
</head>

<body>
	<div class="row js-check-wrap">
		<div class="col-xs-12">
			<ul class="nav nav-tabs" style="margin-bottom:10px;">
				<li class="active"><a href="{:U('Videos/AdminVideos/index')}">视频列表</a></li>
				<li><a href="{:U('Videos/AdminVideos/add')}">添加视频</a></li>
			</ul>

			<form class="well form-search" method="post" action="{:U('AdminVideos/index')}">
				分类:
				<select name="partner_cid" style="width: 200px;" id="selected-cid">
					<option value=''>全部</option>
					<foreach name="cate" item="v">
						<php>$cid_select=$v['cate_id']==$videos_cid?"selected":"";</php>
						<option value="{$v.cate_id}" {$cid_select}>{$v.cate_name}</option>
					</foreach>
				</select>
				<input type="text" name="videos_title" style="width: 300px;" value="{:I('request.vidoes_title/s')}" placeholder="请输入视频名称">
				<input type="submit" class="btn btn-primary" value="搜索" />
				<a class="btn btn-danger" href="{:U('AdminVideos/index')}">清空</a>
			</form>


			<form class="js-ajax-form" method="post">
				<div class="table-actions">
					<button class="btn btn-primary btn-small js-ajax-submit" type="submit" data-action="{:U('Videos/AdminVideos/indexbat','type=order')}">排序</button>
					<button class="btn btn-primary btn-small js-ajax-submit" type="submit" data-action="{:U('Videos/AdminVideos/indexBat','type=delete')}">删除</button>
				</div>
				<table class="table table-hover table-bordered table-list">
					<thead>
						<tr>
							<th width="16"><label><input type="checkbox" class="js-check-all" data-direction="x" data-checklist="js-check-x"></label></th>
							<th width="50">排序</th>
							<th width="50">ID</th>
							<th width="50">视频名称</th>
							<th width="200">视频封面及地址</th>
							<th width="100">填加时间</th>
							<th width="100">操作</th>
						</tr>
					</thead>
					<foreach name="lists" item="v">
					<tr>
						<td style="vertical-align:middle;"><input type="checkbox" class="js-check" data-yid="js-check-y" data-xid="js-check-x" name="ids[]" value="{$v['videos_id']}" title="ID:{$v['videos_id']}"></td>
						<td><input name="orderby[{$v['videos_id']}]" class="input input-order" type="text" size="3" value="{$v['orderby']}" /></td>

						<td>{$v.videos_id}</td>
						<td>{$v.videos_title}</td>
						<td>
							<video src="{:sp_get_image_preview_url($v['videos'])}" width="300" id="videos_content-preview"  controls="controls" poster="{:sp_get_image_preview_url($v['poster_photo'])}">
							您的浏览器不支持 video 标签。
						</video></td>
						<td>{$v.create_time|date="Y-m-d H:i:s",### }</td>
						<td>
							<a href="{:U('Videos/AdminVideos/edit','videos_id='.$v['videos_id'])}">编辑</a> |
							<a href="{:U('Videos/AdminVideos/delete','videos_id='.$v['videos_id'])}" class="js-ajax-delete">删除</a>
						</td>
					</tr>
					</foreach>
					<tfoot>
						<tr>
							<th width="16"><label><input type="checkbox" class="js-check-all" data-direction="x" data-checklist="js-check-x"></label></th>
							<th width="50">排序</th>
							<th width="50">ID</th>
							<th width="50">视频名称</th>
							<th width="200">视频封面及地址</th>
							<th width="100">填加时间</th>
							<th width="100">操作</th>
						</tr>
					</tfoot>
				</table>


				<div class="table-actions">
					<button class="btn btn-primary btn-small js-ajax-submit" type="submit" data-action="{:U('Videos/AdminVideos/indexbat','type=order')}">排序</button>
					<button class="btn btn-primary btn-small js-ajax-submit" type="submit" data-action="{:U('Videos/AdminVideos/indexBat','type=delete')}">删除</button>
				</div>
			</form>


			<nav>
				<ul class="pagination">
					{$page}
				</ul>
			</nav>
		</div>

	</div>
	<script src="__PUBLIC__/js/common.js"></script>
</body>
</html>